<script lang="ts" setup>
import Item from './List/Item.vue'
import type { IDialog } from '@/typings/components'
import uniPopup from '@/uni_modules/uni-popup/components/uni-popup/uni-popup.vue';

const { isLogin } =storeToRefs(useUser())
const popup = ref<IDialog>()
</script>

<template>
  <view mt-6>
    <view class="border_list">
      <Item title="联系客服" icon="contact" @click="popup?.open('center')" mb-50rpx />
      <navigator v-if="isLogin" url="/pages/order/index" open-type="navigate" hover-class="none">
        <Item title="我的订单" icon="order" />
      </navigator>
    </view>

    <view v-if="isLogin" class="border_list" mt-5>
      <navigator url="/pages/mine/pages/settings" open-type="navigate" hover-class="none">
        <Item title="设置" icon="setting" />
      </navigator>
    </view>

    <uni-popup ref="popup" background-color="#fff">
      <view p-4 h-full>
        <image w-550 h-700 src="@/static/images/pages/mine/qrcode_wz.jpg" />
      </view>
    </uni-popup>
  </view>
</template>

<style lang="scss" scoped>
.border_list {
  padding: 35rpx 20rpx;
  border-radius: 15rpx;
  box-shadow: 0 0 10rpx 0rpx rgba(215, 215, 215, 0.35);
}
</style>
